<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"><plist version="1.0"><dict><key>payloads</key><array><dict><key>bundle_id</key><string>com.filewave.policy.general</string><key>description</key><string></string><key>name</key><string>Timed Event</string></dict><dict><key>arguments</key><array/><key>bundle_id</key><string>com.filewave.policy.blocker_script</string><key>environment</key><dict><key>custom_bool</key><string>custom_bool_01</string><key>disable_active_time</key><string>%disable_active_time%</string><key>enable_active_time</key><string>%enable_active_time%</string></dict><key>script</key><string>#!/bin/zsh
#
# FileWave client will execute this script and will suspend deployment depending on the exit code.
# An exit code of anything else than 0 will block the client.
	
current_time=$(date +&quot;%H%M%S&quot;)

function set_time_flag {

	/usr/local/sbin/FileWave.app/Contents/MacOS/fwcld -custom_write -key $custom_bool -value $1
}

if [ $disable_active_time -ge $enable_active_time ]
then
	if [ $current_time -le $disable_active_time ] &amp;&amp; [ $current_time -ge $enable_active_time ]
	then
		set_time_flag 1
	else
		set_time_flag 0
	fi
else
	if [ $current_time -ge $disable_active_time ] &amp;&amp; [ $current_time -le $enable_active_time ]
	then
		set_time_flag 0
	else
		set_time_flag 1
	fi
fi

exit 0</string><key>scriptExtension</key><string>sh</string></dict></array></dict></plist>
